#ifndef EDITSHEET_H
#define EDITSHEET_H

#include <QDialog>
#include <QMap>

class CharacterRecord;
class QWidget;
class QScrollArea;
class TargetData;

class EditSheet : public QDialog
{
    Q_OBJECT
public:
    EditSheet(CharacterRecord *record, QWidget *parent = 0);
    ~EditSheet();
    void setTarget(QWidget *t) { mTarget = t; }
private Q_SLOTS:
    void textChanged(const QString &);
    void valueChanged(int);
    void initPropertyEditor();
private:
    void updateTargetLabel(QWidget *, const QString &, const char *);

    QMap<QWidget *, TargetData> mWidgetToPropMap;
    CharacterRecord *mRecord;
    QScrollArea *mScroll;
    QWidget *mTarget;
};

#endif // EDITSHEET_H
